package com.myk.game.gobangchess.expand.magichero;

import java.util.ArrayList;
import java.util.Arrays;
import java.util.List;

/**
 * 英雄基类
 */
public abstract class Hero {

    public final String name; //英雄名称
    public final String description; //英雄描述
    public final Element ele; //英雄元素属性
    public final Level level; //棋子等级
    public final int originHp; //初始生命值
    public int hp; //当前生命值
    public int atk; //当前攻击力
    public int sp; //当前移动速度
    public final List<Skill> SKILLS; //英雄技能列表

    public Hero(String name, String description,Element ele, Level level, int hp, int atk, int sp, Skill... skills) {
        this.name = name;
        this.description = description;
        this.ele = ele;
        this.level = level;
        this.originHp = hp;
        this.hp = hp;
        this.atk = atk;
        this.sp = sp;
        this.SKILLS = new ArrayList<>(Arrays.asList(skills));
    }

    /**
     * 技能基类
     */
    public static abstract class Skill{

        public Hero hero; //技能所属英雄

        public final String name; //技能名称
        public final String description; //技能描述

        public Skill(String name, String description) {
            this.name = name;
            this.description = description;
        }
    }
}
